//accepted 
#include <cstdio>
int t, n, x, m;
int main(){
	freopen("in.txt","r",stdin);//freopen("out.txt","w",stdout);
	scanf("%d", &t);
	for(int i=1;i<=t;++i){
		scanf("%d", &n);
		m=0;
		for(int j=0;j<n;++j){
			scanf("%d", &x);
			if(x>m)m=x;
		}
		printf("Case %d: %d\n", i, m);
	}
	
	return 0;
}
